import { createRouter, createWebHistory } from 'vue-router'
import HomeView from '../views/HomeView.vue'
import HomePage from '@/views/homePage/index.vue';
import BasePage from '@/views/basePage/index.vue';
import ModelPage from '@/views/modelPage/index.vue';
import DetailPage from '@/views/detailPage/index.vue';

const router = createRouter({
  history: createWebHistory(import.meta.env.BASE_URL),
  routes: [
    {
      path: '/',
      component: HomeView,
      // redirect: '/homePage',
      children: [
        {
          path: '/homePage',
          // name: 'HomePage',
          component: HomePage
        },
        {
          path: '/basePage',
          // name: 'BasePage',
          component: BasePage
        },
        {
          path: '/modelPage',
          // name: 'ModelPage',
          component: ModelPage
        },
        {
          path: '/detailPage',
          // name: 'DetailPage',
          component: DetailPage
        },
      ]
    },
  ]
})

export default router
